8e47daa95471eae70745bb914a1a15e2442de1dc,plugins/sonar-core-plugin/src/test/java/org/sonar/plugins/core/issue/IssueTrackingDecoratorTest.java,IssueTrackingDecoratorTest,manual_issues_should_be_closed_if_manual_rule_is_removed,#,182

Before Change


    Resource file = new File("Action.java").setEffectiveKey("struts:Action.java").setId(123);

    // INPUT : one issue existing during previous scan
    IssueDto unmatchedIssue = new IssueDto().setKee("ABCDE").setReporter("freddy").setStatus("OPEN").setRuleKey_unit_test_only("manual", "Performance");
    when(ruleFinder.findByKey(RuleKey.of("manual", "Performance"))).thenReturn(new Rule("manual", "Performance").setStatus(Rule.STATUS_REMOVED));

    IssueTrackingResult trackingResult = new IssueTrackingResult();

After Change


    Resource file = new File("Action.java").setEffectiveKey("struts:Action.java").setId(123);

    // INPUT : one issue existing during previous scan
    IssueDto unmatchedIssue = new IssueDto().setKee("ABCDE").setReporter("freddy").setLine(1).setStatus("OPEN").setRuleKey_unit_test_only("manual", "Performance");
    when(ruleFinder.findByKey(RuleKey.of("manual", "Performance"))).thenReturn(new Rule("manual", "Performance").setStatus(Rule.STATUS_REMOVED));

    IssueTrackingResult trackingResult = new IssueTrackingResult();